home *** CD-ROM | disk | FTP | other *** search
Text File | 1988-06-23 | 5.4 KB | 137 lines | [TEXT/EDIT] |
- * File: prtrap.inc 29 Dec 1987 JHL
- * A replacement for Absoft's prport.inc and prport.sub .
- * This implements traps for Fortran so that it can be used with toolbx.sub .
- * Culled together by J. Lieske, Jet Propulsion Laboratory, based upon
- * Inside Mac V and Lightspeed Pascal equates.
- *
- * The general calling sequence for procedures is
- * CALL TOOLBX(PrRoutine, Args, xPrRoutine)
- * while that for a function is
- * TOOLBX(PrRoutine, Args, xPrRoutine) .
- * In the above parameters, PrRoutine is the encoded PrGlue (Printer Trap
- * $A8FD) parameter and xPrRoutine is the 'call number' as specified in
- * Inside Mac V Chapter 22. The 'Args' are the sequence of arguments to
- * the procedure or function as specified by Inside Mac.
- * Basically, the xPrRoutine 'call number' is placed on the stack
- * just ahead of the printer trap number ($A8FD) and the Fortran PrRoutine
- * parameter tells Fortran's TOOLBX how to interpret the 'Args' and
- * 'xPrRoutine' values.
- * For example, the routine PrintDefault is called from
- * Fortran as follows: CALL TOOLBX( PRINTDEFAULT, hPrint, xPRINTDEFAULT) .
- *
- * * * * * * * * * * * * * * * * * * * * *
- * Modification history:
- * 12/87 JHL Developed basic parameters from Absoft's documentation
- * of toolbx.sub and Apple's Inside Mac V and Lightspeed
- * Pascal.
- * * * * * * * * * * * * * * * * * * * * *
- * PROCEDURE PrOpen;
- INTEGER*4 PROPEN, xPROPEN
- PARAMETER (PROPEN=Z'8FD10000', xPROPEN=Z'C8000000')
-
- * PROCEDURE PrClose;
- INTEGER*4 PRCLOSE, xPRCLOSE
- PARAMETER (PRCLOSE=Z'8FD10000', xPRCLOSE=Z'D0000000')
-
- * PROCEDURE PrintDefault (hPrint: THPrint);
- INTEGER*4 PRINTDEFAULT, xPRINTDEFAULT
- PARAMETER (PRINTDEFAULT=Z'8FD12000', xPRINTDEFAULT=Z'20040480')
-
- * FUNCTION PrValidate (hPrint: THPrint) : BOOLEAN;
- INTEGER*4 PRVALIDATE, xPRVALIDATE
- PARAMETER (PRVALIDATE=Z'8FDD2000', xPRVALIDATE=Z'52040498')
-
- * FUNCTION PrStlDialog (hPrint: THPrint) : BOOLEAN;
- INTEGER*4 PRSTLDIALOG, xPRSTLDIALOG
- PARAMETER (PRSTLDIALOG=Z'8FDD2000', xPRSTLDIALOG=Z'2A040484')
-
- * FUNCTION PrJobDialog (hPrint: THPrint) : BOOLEAN;
- INTEGER*4 PRJOBDIALOG, xPRJOBDIALOG
- PARAMETER (PRJOBDIALOG=Z'8FDD2000', xPRJOBDIALOG=Z'32040488')
-
- * PROCEDURE PrJobMerge (hPrintSrc, hPrintDst: THPrint);
- INTEGER*4 PRJOBMERGE, xPRJOBMERGE
- PARAMETER (PRJOBMERGE=Z'8FD12400', xPRJOBMERGE=Z'5804089C')
-
- * FUNCTION PrOpenDoc (hPrint: THPrint; pPrPort: TPPrPort;
- * pIOBuf: Ptr) : TpPrPort;
- INTEGER*4 PROPENDOC, xPROPENDOC
- PARAMETER (PROPENDOC=Z'8FD92480', xPROPENDOC=Z'04000C00')
-
- * PROCEDURE PrCloseDoc (pPrPort: TPPrPort);
- INTEGER*4 PRCLOSEDOC, xPRCLOSEDOC
- PARAMETER (PRCLOSEDOC=Z'8FD12000', xPRCLOSEDOC=Z'08000484')
-
- * PROCEDURE PrOpenPage (pPrPort: TPPrPort; pPageFrame: TPRect);
- INTEGER PROPENPAGE, xPROPENPAGE
- PARAMETER (PROPENPAGE=Z'8FD12400', xPROPENPAGE=Z'10000808')
-
- * PROCEDURE PrClosePage (pPrPort: TPPrPort);
- INTEGER*4 PRCLOSEPAGE, xPRCLOSEPAGE
- PARAMETER (PRCLOSEPAGE=Z'8FD12000', xPRCLOSEPAGE=Z'1800040C')
-
-
- * Note: prStatus should actually be passed as a pointer to a TPrStatus
- * record.
- * PROCEDURE PrPicFile (hPrint: THPrint; pPrPort: TPPrPort; pIOBuf: Ptr;
- * pDevBuf: Ptr; VAR prStatus: TPrStatus);
- INTEGER*4 PRPICFILE, xPRPICFILE
- PARAMETER (PRPICFILE=Z'8FD124B2', xPRPICFILE=Z'60051480')
-
- * FUNCTION PrError : INTEGER;
- INTEGER*4 PRERROR, xPRERROR
- PARAMETER (PRERROR=Z'8FD50000', xPRERROR=Z'BA000000')
-
- * PROCEDURE PrSetError(iErr : INTEGER);
- INTEGER*4 PRSETERROR, xPRSETERROR
- PARAMETER (PRSETERROR=Z'8FD0A000', xPRSETERROR=Z'C0000200')
-
- * PROCEDURE PrDrvrOpen;
- INTEGER*4 PRDRVROPEN, xPRDRVROPEN
- PARAMETER (PRDRVROPEN=Z'8FD10000', xPRDRVROPEN=Z'80000000')
-
- * PROCEDURE PrDrvrClose;
- INTEGER*4 PRDRVRCLOSE, xPRDRVRCLOSE
- PARAMETER (PRDRVRCLOSE=Z'8FD10000', xPRDRVRCLOSE=Z'88000000')
-
- * PROCEDURE PrCtlCall(iWhichCtl: Integer; lParam1, lparam2, lparam3: LongInt);
- INTEGER*4 PRCTLCALL, xPRCTLCALL
- PARAMETER (PRCTLCALL=Z'8FD0A490', xPRCTLCALL=Z'A0000E00')
-
- * FUNCTION PrDrvrDCE: Handle;
- INTEGER*4 PRDRVRDCE, xPRDRVRDCE
- PARAMETER (PRDRVRDCE=Z'8FD90000', xPRDRVRDCE=Z'94000000')
-
- * FUNCTION PrDrvrVers: Integer;
- INTEGER*4 PRDRVRVERS, xPRDRVRVERS
- PARAMETER (PRDRVRVERS=Z'8FD50000', xPRDRVRVERS=Z'9A000000')
-
- * PROCEDURE PrGeneral(pData: Ptr);
- INTEGER*4 PRGENERAL, xPRGENERAL
- PARAMETER (PRGENERAL=Z'8FD12000', xPRGENERAL=Z'70070480')
- * PrGeneral is the gateway to the calls documented in Inside Mac V
- * concerning added capabilities for printer resolution, etc.
- * See the file PrGenDefs.inc and the demo program for usage
-
- * PROCEDURE PrPurge;
- INTEGER*4 PRPURGE, xPRPURGE
- PARAMETER (PRPURGE=Z'8FD10000', xPRPURGE=Z'A8000000')
-
- * PROCEDURE PrNoPurge;
- INTEGER*4 PRNOPURGE, xPRNOPURGE
- PARAMETER (PRNOPURGE=Z'8FD10000', xPRNOPURGE=Z'B0000000')
-
- * FUNCTION PrStlInit (hPrint: THPrint): TPPrDlg;
- INTEGER*4 PRSTLINIT, xPRSTLINIT
- PARAMETER (PRSTLINIT=Z'8FD92000', xPRSTLINIT=Z'3C04040C')
-
- * FUNCTION PrJobInit (hPrint: THPrint): TPPrDlg;
- INTEGER*4 PRJOBINIT, xPRJOBINIT
- PARAMETER (PRJOBINIT=Z'8FD92000', xPRJOBINIT=Z'44040410')
-
- * FUNCTION PrDlgMain(hPrint: THPrint; pDlgInit: ProcPtr): Boolean;
- INTEGER*4 PRDLGMAIN, xPRDLGMAIN
- PARAMETER (PRDLGMAIN=Z'8FDD2400', xPRDLGMAIN=Z'4A040894')
-
- * end of prtrap.inc listing
-